import React, { Suspense } from "react";
import ReactDom from "react-dom/client";
import { HashRouter } from "react-router-dom";
import { ThemeProvider } from "styled-components";
import { Provider } from "react-redux";

import App from "@/App";
import theme  from "./assets/theme";
import store from "@/store/store.js";
import "@/assets/css/index.css";


const rootEl = document.getElementById("root");

const root = ReactDom.createRoot(rootEl);

root.render((
  <Suspense fallback="Loading...">
    <Provider store={store}>
      <ThemeProvider theme={theme}>
        <HashRouter>
          <App></App>
        </HashRouter>
      </ThemeProvider>
    </Provider>
  </Suspense>
));
